<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <script src="../../vue.js/vue.js"></script>
  </head>
  <body>
    <!-- 准备vue的容器 -->
    <div id="app">
      {{ message }}
      <button-counter></button-counter>
    </div>

    <script>
      Vue.config.productionTip = false;

      Vue.component('button-counter', {
        data: function () {
          return {
            count: 0,
          };
        },
        template:
          '<button v-on:click="count++">You clicked me {{ count }} times.</button>',
      });
      new Vue({
        el: '#app',
        data: {
          message: 'hello world123',
        },
      });
      function a() {
        return {
          aa: 1,
          bb: 2,
        };
      }

      let xd = a();
      let xd1 = a();
    </script>
  </body>
</html>
